package com.houg.testuserapi.model.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.util.Date;
import lombok.Data;

@Data
@TableName(value = "user")
public class User {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.INPUT)
    private Integer id;

    /**
     * 用户唯一ID
     */
    @TableField(value = "user_id")
    private String userId;

    /**
     * 用户名称
     */
    @TableField(value = "name")
    private String name;

    /**
     * 密码
     */
    @TableField(value = "password")
    private String password;

    /**
     * 最后登录时间
     */
    @TableField(value = "last_login")
    private Date lastLogin;

    /**
     * 注册时间
     */
    @TableField(value = "register_date")
    private Date registerDate;

    /**
     * 状态，1为正常，0为注销，2为禁封，其他为异常
     */
    @TableField(value = "user_state")
    private Integer userState;

    public static final String COL_ID = "id";

    public static final String COL_USER_ID = "user_id";

    public static final String COL_NAME = "name";

    public static final String COL_PASSWORD = "password";

    public static final String COL_LAST_LOGIN = "last_login";

    public static final String COL_REGISTER_DATE = "register_date";

    public static final String COL_USER_STATE = "user_state";
}